/**
 * Created by Panda on 16/01/2017
 */
(function () {
    'use strict';

    var naviItems = [
        {
            text: "系统链接",
            state: "app.sysconnection"
        },
        {
            text: "培训申报",
            state: "app.train"
        },
        {
            text: "科研成果",
            state: "app.scientific"
        },
        {
            text: "学生信息",
            state: "app.student"
        },
        {
            text: "会员管理",
            state: "app.member"
        },
        {
            text: "课程体系",
            state: "app.course"
        },
        {
            text: "教学课件",
            state: "app.courseware"
        }
    ];

    angular
        .module('com.akxx.aqzyk')
        .controller('NaviAController', NaviAController);


    /** @ngInject */
    function NaviAController($state) {
        var vm = this;

        vm.naviItems = naviItems;
        //默认的选择中项，暂时是'教学课件'
        vm.active = 6;

        vm.go = function (index) {
            vm.active = index;
            var state = naviItems[index].state;
            if(!!state){
                $state.go(state);
            }
        };

    }

})();
